<? include("views/cabecera.php"); ?>
<? include("views/menu.php"); ?>
<?
	$titulo_form = "Alta Veh&iacute;culo";
	
	$id = ($tipop=="M") ? $dato->get_data("id") : "";
	$patente = ($tipop=="M") ? $dato->get_data("patente") : "";
	$id_empresa = ($tipop=="M") ? $dato->get_data("id_empresa") : "";
	$detalle = ($tipop=="M") ? $dato->get_data("detalle") : "";
	$nombre = ($tipop=="M") ? $empresa->get_data("razon_social") : "";

	if($tipop=="M")
	{
		$titulo_form = "Edici&oacute;n Veh&iacute;culo (Nro.: ".$id.")";
	}
?>
<form name="frmVehiculo" action="" method="post">
<input type="hidden" name="tipop" id="tipop" value="<? echo($tipop)?>" />
<input type="hidden" name="id_vehiculo" id="id_vehiculo" value="<? echo($id)?>" />
<input type="hidden" name="id_empresa" id="id_empresa" value="<? echo($id_empresa)?>" />
<table  align="center" border="0" cellpadding="0" cellspacing="0" id="formulario">
	<tr>
		<th align="left" colspan="3"><? echo($titulo_form) ?></th>
    </tr>
    <tr>
    	<td align="right" class="etiqueta_form">Patente:</td>
        <td align="left" class="etiqueta_form" colspan="1">
        <input type="text" name="patente" id="patente" value="<? echo($patente); ?>" valida="requerido" tipovalida="texto" class="input_form_medio" onFocus="resaltar(this)" onBlur="noresaltar(this);" tabindex="0" maxlength="6"/>
        </td>
        <td align="left" class="etiqueta_form" >
       
        </td>
    </tr>
    <tr>
    	<td align="right" class="etiqueta_form">Empresa:</td>
        <td align="left" class="etiqueta_form" colspan="1">
        <input type="text" name="nombre" id="nombre" value="<?=$nombre?>" grabar="S" valida="requerido" tipovalida="texto" class="input_form_largo" onFocus="resaltar(this)" onBlur="noresaltar(this);"/>
        </td>
        <td align="left" class="etiqueta_form" >
       
        </td>
    </tr>
     <tr>
    	<td align="right" class="etiqueta_form" valign="top">Detalle:</td>
        <td align="left" class="etiqueta_form" colspan="1">
        <textarea name="detalle" id="detalle" onFocus="resaltar(this)" onBlur="noresaltar(this)" class="text_area_form"><?=$detalle?></textarea>
        </td>
        <td align="left" class="etiqueta_form" >
       
        </td>
    </tr>
     <tr>
        <td colspan="3" height="5">
         </td>
    </tr>
    <tr>
        <td colspan="3">
        	<span id="mensaje"></span>
         </td>
    </tr>   
    <tr>
        <td colspan="3" align="center" height="50">
        	<input  type="button" name="btngrabar" id="btngrabar" onclick="grabarForm('<?=$controller?>')"  value="Grabar" class="boton_form" onMouseOver='overClassBoton(this)' onMouseOut='outClassBoton(this)'/>&nbsp;
            <input  type="button" name="btnsalir" id="btnsalir" onclick="salirForm('<?=$controller?>')"value="Cancelar" class="boton_form" onMouseOver='overClassBoton(this)' onMouseOut='outClassBoton(this)' />
         </td>
    </tr>
</table>
</div>
</form>
<? include("views/pie.php"); ?>